home *** CD-ROM | disk | FTP | other *** search
/ BCI NET / BCI NET Dec 94.iso / archives / programming / blitzbasic / blitz-list200994.lha / blitz-list / 000499_blitz-list-request_Thu Jul 21 07:20:02 1994.msg < prev    next >
Internet Message Format  |  1994-09-20  |  2KB

  1. Received: from iconz.co.nz (iconz.co.nz [202.14.100.2]) by kantti.helsinki.fi (8.6.9/8.6.5) with SMTP id HAA23582 for <blitz-list@HELSINKI.FI>; Thu, 21 Jul 1994 07:19:49 +0300
  2. Received: (acid@localhost) by iconz.co.nz (8.6.6.Beta6/8.6.6.Beta6) id QAA08509; Thu, 21 Jul 1994 16:18:17 +1200
  3. Date: Thu, 21 Jul 1994 16:14:33 +1200 (NZST)
  4. From: Acid Software <acid@iconz.co.nz>
  5. Subject: Re: Are numbers REAL?
  6. To: "GEORGAKAKIS, LOUIS, MR" <BB4H@MUSICB.MCGILL.CA>
  7. cc: blitz-list@HELSINKI.FI
  8. In-Reply-To: <20JUL94.23591303.0080.MUSIC@MUSICB.MCGILL.CA>
  9. Message-ID: <Pine.3.87.9407211633.A8457-0100000@iconz.co.nz>
  10. MIME-Version: 1.0
  11. Content-Type: TEXT/PLAIN; charset=US-ASCII
  12. X-Status: 
  13. Status: RO
  14.  
  15.  
  16.  
  17. On Wed, 20 Jul 1994, GEORGAKAKIS,LOUIS,MR wrote:
  18.  
  19. > Can someone tell me why, when I write down this little program,
  20. > it doesn't do what I tell it to?  Here:
  21. > Print 5.7896
  22. > MouseWait
  23. > This should print out 5.7896 in a Shell window right? WRONG! It prints
  24. > out:
  25. > 5.789599
  26. > Why?  WHY!?
  27. > Sigh.
  28. > Nelson Santos
  29. > Mr. Mig
  30. Binary numbers don't store very well unless you use floating point. For 
  31. speed Blitz defaults to fixed point, which means 2 to the power of hmmm, 
  32. -14 is the smallest fraction, once you look at the number closest to this 
  33. you can see in decimal the 3 rd place decimal get's shaky!
  34.  
  35. Anyway, either think binary like a good programmer or think floating 
  36. point, I have warned against Blitz2 being suitable for large figures, 
  37. both feminine and financial, so if it's one of the two ring HiSoft 
  38. immediately.
  39.  
  40. Simon
  41.  
  42.